package com.kkb.domain;

import com.kkb.Document;
import com.kkb.domain.enums.Property;

import java.util.Optional;

/**
 * @Author kkb
 * @Description HasPrice 价格类
 * @Date 2024/8/1 15:25
 * @Version 1.0
 */

public interface HasPrice extends Document {
    default Optional<Number> getPrice() {
        return Optional.ofNullable((Number) get(Property.PRICE.toString()));
    }
}
